page.tsx 773 B

1234567891011121314151617181920212223242526272829
  1. import React from 'react'
  2. import { getLocaleOnServer } from '@/i18n/server'
  3. import { useTranslation } from '@/i18n/i18next-serverside-config'
  4. import Form from '@/app/components/datasets/settings/form'
  5. type Props = {
  6. params: { datasetId: string }
  7. }
  8. const Settings = async ({
  9. params: { datasetId },
  10. }: Props) => {
  11. const locale = getLocaleOnServer()
  12. const { t } = await useTranslation(locale, 'dataset-settings')
  13. return (
  14. <div className='bg-white h-full'>
  15. <div className='px-6 py-3'>
  16. <div className='mb-1 text-lg font-semibold text-gray-900'>{t('title')}</div>
  17. <div className='text-sm text-gray-500'>{t('desc')}</div>
  18. </div>
  19. <div>
  20. <Form datasetId={datasetId} />
  21. </div>
  22. </div>
  23. )
  24. }
  25. export default Settings